package com.dong.designPattern.prototype;

import com.dong.designPattern.prototype.entity.Student;
import org.junit.Test;

import java.io.IOException;

public class PrototypeTest {
    @Test
    public void test1() throws CloneNotSupportedException, IOException, ClassNotFoundException {
        Student student = new Student();
        student.setId("1");
        student.setName("Dong");
        student.setAge(20);

        Student student1 = (Student) student.clone();
        Student student2 = (Student) student.deepClone();

        System.out.println(1);
    }
}
